<script setup>
import { ref } from 'vue'
import Login from './components/Login.vue'

const isLoggedIn = ref(false)

// 确保 electron 对象存在
const electron = window.electron

if (electron) {
  electron.on('login-response', (success) => {
    isLoggedIn.value = success
  })
}
</script>

<template>
  <router-view></router-view>
</template>

<style>
/* 全局样式 */
@import './styles/theme.css';

html, body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

#app {
  width: 100%;
  height: 100%;
  overflow: hidden;
}

/* 滚动条样式 */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: var(--text-hint);
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--text-disabled);
}
</style>
